package cn.mldn.microcloud.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import cn.mldn.microcloud.mapper.IDeptDoaMapper;
import cn.mldn.microcloud.service.IDeptService;
import cn.mldn.vo.Dept;

@Service
public class IDeptServiceImpl implements IDeptService {

	@Resource
	private IDeptDoaMapper deptDAO;

	@Override
	public Dept get(long id) {
		return deptDAO.findById(id);
	}

	@Override
	public boolean add(Dept dept) {
		return deptDAO.doCreate(dept);
	}

	@Override
	public List<Dept> list() {
		return deptDAO.findAll();
	}

}
